home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 45
/
Aminet 45 (2001)(GTI - Schatztruhe)[!][Oct 2001].iso
/
Aminet
/
game
/
role
/
ldmud-3.2-bin.lha
/
mud
/
doc
/
efun
/
invert_bits
< prev
next >
Wrap
Text File
|
2001-04-06
|
543b
|
22 lines
SYNOPSIS
string invert_bits (string str)
DESCRIPTION
Invert the status of all bits in bitstring <str> and return the
new string.
Note that the total number of bits (ie the string length) stays
the same.
EXAMPLES
string s;
s = set_bit("", 3); s = set_bit(s, 4); s = set_bit(s, 15);
--> s is now "8 ("
invert_bits(s) --> returns "G_W"
SEE ALSO
set_bit(E), clear_bit(E), test_bit(E), last_bit(E), and_bits(E),
or_bits(E), xor_bits(E), count_bits(E)